home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
MacWorld 1999 January - Disc 2
/
Macworld (1999-01) (Disk 2).dmg
/
Serious Demos
/
Symbolic Composer 4.2
/
Environment
/
Projects
/
Contributed Scores
/
Piano Inventions
/
Invention 1
< prev
next >
Wrap
Lisp/Scheme
|
1998-10-26
|
7KB
|
238 lines
; Invention I - solo keyboard (section 1)
(setq tonal (activate-tonality (chromatic c 3))
tonal1 (activate-tonality (chromatic c 4))
tonal2 (activate-tonality (chromatic c 5))
tonal3 (activate-tonality (whole-tone c 6))
)
(setq sym1 '(l k a c)
sym2 (gen-random 0.4 8 sym1)
sym3 '(= b c e f lc -b ka -b -c)
sym4 (gen-random-variate 0.4 0.07 -3 3 sym3)
)
(setq rhy1 '(1/8 1/8 -1/8t 1/8t 1/8t 1/16 1/16 1/16 1/16)
rhy2 (gen-loop '((1 5 1) (2 5 1))
'(-1/4-5 1/4-5 1/4-5 1/4-5 1/4-5 1/4-5))
rhy3 '(1/2 1/16 -1/2)
rhy4 (gen-loop '((1 4 1) (2 5 2)) '(-1/32 1/32 1/32 1/32 1/32))
)
(def-symbol
p1 sym2
p2 sym1
p3 sym4
p4 sym3
p5 '(aelsx)
p6 (find-change (gen-fibonacci-trans 4 sym1 sym2))
)
(def-length
p1 '(1/16 1/16 1/16 1/16 -1/16 1/16 -1/16 1/16
1/16 1/16 1/16 -1/8 1/16 1/16)
p2 '(1/8 -1/8 1/8 1/8 -1/8 1/8 1/8 1/8)
p3 rhy1
p4 rhy2
p5 rhy3
p6 rhy4
)
(compile-song "ccl;output:" 1/4 "invention1a"
; !---!---!---!---!---!---!---!---!---
p1 tonal " --- - -- - "
p2 tonal3 " ---- - -- - "
p3 tonal1 " --- -- "
p4 tonal2 " -- --- -- "
p5 tonal "-- - "
p6 tonal2 " --- ---- "
)
; Invention 1 - solo keyboard (section 2)
(setq tonal (activate-tonality (chromatic c 3))
tonal1 (activate-tonality (chromatic c 4))
tonal2 (activate-tonality (chromatic c 5))
tonal3 (activate-tonality (whole-tone c 6))
)
(setq sym1 '(l k a c)
sym2 (gen-random 0.4 8 sym1)
sym3 '(= b c e f lc -b ka -b -c)
sym4 (gen-random-variate 0.4 0.07 -3 3 sym3)
)
(def-neuron ext1
(or (in 1 '(l k))
(in 2 '(k k))
(in 3 '(lc -b))
(in 4 '(b b)))
(fill-template (append sym1 sym2 sym3 sym4)
(gen-fibonacci-trans 4 sym1 sym2))
(otherwise (list (in 1 0) (in 2 0) (in 3 0) (in 4 0)))
)
(setq sym5 (run-neuron 'ext1
sym1 sym2 sym3 sym4)
)
; -> (l k a c d d b l l l l d = n m c e o n d f g = g e o o o o g p o
;l k a c d d b l l l l d = n m c e o n d f g = g e o o o o g p o a a c b
;l k a c d d b l l l l d = n m c e o n d f g = g e o o o o g p o)
(setq rhy1 '(1/8 1/8 -1/8t 1/8t 1/8t 1/16 1/16 1/16 1/16)
rhy2 (gen-loop '((1 5 1) (2 5 1))
'(-1/4-5 1/4-5 1/4-5 1/4-5 1/4-5 1/4-5))
rhy3 '(1/2 1/16 -1/2)
rhy4 (gen-loop '((1 4 1) (2 5 2)) '(-1/32 1/32 1/32 1/32 1/32))
)
(def-neuron ext2
(in 1 '(l k a c)) '(1/16 1/16 1/16 1/16)
(in 1 '(b l l l l)) '(-1/4-5 1/4-5 1/4-5 1/4-5 1/4-5)
(in 1 '(o o o o)) '(-1/32 1/32 1/32 1/32)
(in 1 '(n d f g)) '(1/32 1/32 1/32 1/32)
(otherwise '1/8)
)
(setq rhy5 (run-neuron 'ext2
sym5)
)
(def-symbol
p1 sym2
p2 sym1
p3 sym4
p4 sym3
p5 '(aelsx)
p6 (find-change (gen-fibonacci-trans 4 sym1 sym2))
p7 sym5
)
(def-length
p1 '(1/16 1/16 1/16 1/16 -1/16 1/16 -1/16 1/16
1/16 1/16 1/16 -1/8 1/16 1/16)
p2 '(1/8 -1/8 1/8 1/8 -1/8 1/8 1/8 1/8)
p3 rhy1
p4 rhy2
p5 rhy3
p6 rhy4
p7 rhy5
)
(compile-song "ccl;output:" 1/4 "invention1b"
; !---!---!---!---!---!---!---!---!---!---
p1 tonal "- - --- -- --"
p2 tonal3 " --- "
p3 tonal1 " - --- "
p4 tonal2 " -- --- - "
p5 tonal " -- - "
p6 tonal2 " --- ---- "
p7 tonal2 "---- ----- ------ -------"
)
; Invention 1 - solo keyboard (section 3)
(setq tonal (activate-tonality (chromatic c 3))
tonal1 (activate-tonality (chromatic c 4))
tonal2 (activate-tonality (chromatic c 5))
tonal3 (activate-tonality (whole-tone c 6))
)
(setq sym1 '(l k a c)
sym2 (gen-random 0.4 8 sym1)
sym3 '(= b c e f lc -b ka -b -c)
sym4 (gen-random-variate 0.4 0.07 -3 3 sym3)
)
(setq ch1 '(aelsx)
(setq ch2 (gen-random-variate 0.4 0.07 -3 3
(gen-random 0.4 34 '(aelsx ae lsx a elx))))
;-->(ae aelsx a lsx elx dkw mty -b krw cg krw cjv fmy cgnuz cg mty c nuz dh
;a lsx -b mty aelsx aelsx ae fmy fmy -b ae ae krw ae elx)
(def-neuron ext1
(or (in 1 '(l k))
(in 2 '(k k))
(in 3 '(lc -b))
(in 4 '(b b)))
(fill-template (append sym1 sym2 sym3 sym4)
(gen-fibonacci-trans 4 sym1 sym2))
(otherwise (list (in 1 0) (in 2 0) (in 3 0) (in 4 0)))
)
(setq sym5 (run-neuron 'ext1
sym1 sym2 sym3 sym4)
)
;--> (l k a c d d b l l l l d = n m c e o n d f g = g e o o o o g p o
;l k a c d d b l l l l d = n m c e o n d f g = g e o o o o g p o a a c b
;l k a c d d b l l l l d = n m c e o n d f g = g e o o o o g p o)
(setq rhy1 '(1/8 1/8 -1/8t 1/8t 1/8t 1/16 1/16 1/16 1/16)
rhy2 (gen-loop '((1 5 1) (2 5 1))
'(-1/4-5 1/4-5 1/4-5 1/4-5 1/4-5 1/4-5))
rhy3 '(1/2 1/16 -1/2)
rhy4 (gen-loop '((1 4 1) (2 5 2)) '(-1/32 1/32 1/32 1/32 1/32))
)
(def-neuron ext2
(in 1 '(l k a c)) '(1/16 1/16 1/16 1/16)
(in 1 '(b l l l l)) '(-1/4-5 1/4-5 1/4-5 1/4-5 1/4-5)
(in 1 '(o o o o)) '(-1/32 1/32 1/32 1/32)
(in 1 '(n d f g)) '(1/32 1/32 1/32 1/32)
(otherwise '1/8)
)
(setq rhy5 (run-neuron 'ext2
sym5)
)
(setq rhy6 (gen-random-keep 0.4 34 '(1 2 3 4 5 6 7 8 9 10 13 14 15 20)
(append rhy2 rhy1 rhy3
(change-length times 2 rhy4))
'(1/4 1/16 1/8 1/8 1/8 -1/8)))
;-->(-1/4-5 1/4-5 1/4-5 1/4-5 1/4-5 1/4-5 1/4-5 1/4-5 1/4-5 1/4-5 -1/8 1/16
;-1/8t 1/8t 1/8t 1/8 1/8 1/8 1/8 1/2 -1/8 -1/8 1/16 1/4 1/4 1/8 1/8
;1/8 1/8 1/16 1/8 1/8 1/8 1/16)
(def-symbol
p1 sym2
p2 sym1
p3 sym4
p4 sym3
p5 ch2
p6 (find-change (gen-fibonacci-trans 4 sym1 sym2))
p7 sym5
)
(def-length
p1 '(1/16 1/16 1/16 1/16 -1/16 1/16 -1/16 1/16
1/16 1/16 1/16 -1/8 1/16 1/16)
p2 '(1/8 -1/8 1/8 1/8 -1/8 1/8 1/8 1/8)
p3 rhy1
p4 rhy2
p5 rhy6
p6 rhy4
p7 rhy5
)
(compile-song "ccl;output:" 1/4 "invention1c"
; !---!---!---!---!---!---!---!---!---!---!---!
p1 tonal " -- - -- - - - - -- "
p2 tonal3 " "
p3 tonal1 " "
p4 tonal2 " "
p5 tonal1 "---- ----- ------ ------- ----"
p6 tonal2 " "
p7 tonal2 " ------- -- --------- "
)